<?php defined('SYSPATH') or die(); ?>
<!doctype html>
<html>
<head>
    <meta charset="utf-8">
    <title>思途CMS{$coreVersion}</title>
    {template 'stourtravel/public/public_min_js'}
    {php echo Common::getCss('style.css,base.css,base_new.css,equity.css'); }
    {php echo Common::getScript("uploadify/jquery.uploadify.min.js,product_add.js,choose.js,st_validate.js,jquery.colorpicker.js,jquery.jqtransform.js,imageup.js,jqueryui/jquery-ui.min.js"); }
</head>
<body>
<!--顶部-->
<table class="content-tab">
    <tr>
        <td valign="top" class="content-rt-td" style="overflow:auto;">
            <div class="product-add-wrap pl-20">
                <ul class="layer-equity-list clearfix" style="width: 700px">
                    {loop $list['zdy_list'] $v}
                    <li data-id="{$v['id']}" class="mr-10">
                        <a href="javascript:;" class="layer-equity-item">
                            <img class="icon" src="{$v['icon']}">
                            <div class="text">{$v['title']}</div>
                        </a>
                    </li>
                    {/loop}
                </ul>
            </div>
            <div class="clear text-c f-0 mt-30 mt-10">
                <a href="javascript:;" class="btn btn-primary radius ml-20" id="confirm_btn">确定</a>
            </div>
        </td>
    </tr>
</table>
<script>
    $(function(){
        $('.layer-equity-list li').on('click',function(){
            if($(this).hasClass('active')){
                $(this).removeClass('active');
            }else{
                $(this).addClass('active');
            }
        });

        $('#confirm_btn').click(function(){
            var id = [];
            $('.layer-equity-list li.active').each(function (){
                id.push($(this).attr('data-id'));
            });
            if(!id){
                ST.Util.showMsg('请选择图标！', 1);
                return false;
            }
            ST.Util.responseDialog({id:id},true);
        });
    })

    function add_equity()
    {
        var url = SITEURL+'equity/dialog_add_equity';
        CHOOSE.setSome(
            "设置目的地",
            {maxHeight:500,loadWindow:window,loadCallback:Product.listDest},
            url,
            1
        )
    }
</script>
</body>
</html>